package com.lx.core.weight.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lx.core.weight.entity.Weight;
import com.lx.core.weight.entity.dto.EmployerStaticDTO;
import com.lx.core.weight.entity.dto.WeightPageDTO;
import com.lx.core.weight.entity.vo.*;
import com.lx.framework.core.entity.SysAdmin;
import com.lx.framework.core.model.SysAdminDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author lx
 * @date 2025/08/26 09:20
 **/
@Mapper
public interface WeightMapper extends BaseMapper<Weight> {
    IPage<WeightPageList> findWeightPage(IPage<WeightVO> page, @Param("weightPageDTO") WeightPageDTO weightPageDTO);

    FeeTotalVO getTotalByQuery(@Param("weightPageDTO")WeightPageDTO weightPageDTO);
    List<WeightPageList> exportExcel(@Param("weightPageDTO")WeightPageDTO weightPageDTO);

    List<CurrentDayGoodsWeightVO> getCurrentDayGoodsWeight();

    List<PriceLastSevenGoodsVO> getLastSevenDayAveragePrice(@Param("goodsType")int goodsType);

    List<PriceLastFiveYearGoodsVO> getPastFiveYearGoodsTypePriceByDay(@Param("goodsType")int goodsType);

    List<WeightLastFiveYearGoodsVO> getPastFiveYearGoodsTypeWeightByDay(@Param("goodsType")int goodsType);

    List<PriceLastFiveYearGoodsVO> getPastFiveYearGoodsTypePriceByWeek(@Param("goodsType")int goodsType);

    List<WeightLastFiveYearGoodsVO> getPastFiveYearGoodsTypeWeightByWeek(@Param("goodsType")int goodsType);

    List<PriceLastFiveYearGoodsVO> getPastFiveYearGoodsTypePriceByMonth(@Param("goodsType")int goodsType);

    List<WeightLastFiveYearGoodsVO> getPastFiveYearGoodsTypeWeightByMonth(@Param("goodsType")int goodsType);

    List<FeeLastMonthVO> getLastMonthDayFee(@Param("goodsType")int goodsType);

    List<WeightNumberUseInfoVO> getCurrentWeightNumberUse(@Param("goodsType")int goodsType);

    Page<SysAdminDTO> getSyaAdminPage(IPage<SysAdminDTO> page, String username);

    IPage<EmployerWeightCountList> getEmployerWeightCount(IPage<EmployerWeightCountVO> page, @Param("employerStaticDTO") EmployerStaticDTO employerStaticDTO);
}
